<div class="header">
    <div class="menu-btn">
        <div class="menu"></div>
    </div>
    <h1 class="logo">
        <a href="/">
            <span>MYBLOG</span>
            <img src="/static/img/logo.png">
        </a>
    </h1>
    <div class="nav">
        <a href="/"        {{if equrl .Path "/"}}        class="active"{{end}}>首页</a>
        <a href="/whisper" {{if equrl .Path "/whisper"}} class="active"{{end}}>微语</a>
        <a href="/leacots" {{if equrl .Path "/leacots"}} class="active"{{end}}>留言</a>
        <a href="/album"   {{if equrl .Path "/album"}}   class="active"{{end}}>相册</a>
        <a href="/about"   {{if equrl .Path "/about"}}   class="active"{{end}}>关于</a>
    </div>
    <ul class="layui-nav header-down-nav">
        <li class="layui-nav-item">
            <a href="/" {{if equrl .Path "/"}} class="active"{{end}}>
                <i class="layui-icon layui-icon-home"></i>
                <span class="nav_menu">首页</span>
            </a>
        </li>
        <li class="layui-nav-item">
            <a href="/whisper" {{if equrl .Path "/whisper"}} class="active"{{end}}>
                <i class="layui-icon layui-icon-read"></i>
                <span class="nav_menu">微语</span>
            </a>
        </li>
        <li class="layui-nav-item">
            <a href="/leacots" {{if equrl .Path "/leacots"}} class="active"{{end}}>
                <i class="layui-icon layui-icon-dialogue"></i>
                <span class="nav_menu">留言</span>
            </a>
        </li>
        <li class="layui-nav-item">
            <a href="/album" {{if equrl .Path "/album"}} class="active"{{end}}>
                <i class="layui-icon layui-icon-carousel"></i>
                <span class="nav_menu">相册</span>
            </a>
        </li>
        <li class="layui-nav-item">
            <a href="/about"   {{if equrl .Path "/about"}}   class="active"{{end}}>
                <i class="layui-icon layui-icon-about"></i>
                <span class="nav_menu">关于</span>
            </a>
        </li>
        {{if .isLogin}}
            <li class="layui-nav-item">
                <a href="/ucenter"   {{if equrl .Path "/ucenter"}}   class="active"{{end}}>
                    <i class="layui-icon layui-icon-username "></i>
                    <span class="nav_menu">{{.User.Name}}</span>
                </a>
            </li>
            <li class="layui-nav-item">
                <a href="/logout"   {{if equrl .Path "/logout"}}   class="active"{{end}}>
                    <i class="layui-icon layui-icon-spread-left"></i>
                    <span class="nav_menu">退出</span>
                </a>
            </li>
        {{else}}
            <li class="layui-nav-item">
                <a href="/user"   {{if equrl .Path "/user"}}   class="active"{{end}}>
                    <i class="layui-icon layui-icon-username "></i>
                    <span class="nav_menu">我的</span>
                </a>
            </li>
        {{end}}
    </ul>
    <p class="welcome-text">
    {{if .isLogin}}
        <a href="/ucenter">
            <i class="layui-icon layui-icon-username" style="color: #ff7f21;"></i>
            <span class="side_menu">欢迎,{{.User.Name}}
                <a href="/logout" style="color: #ff7f21;">退出</a>
            </span>
        </a>
    {{else}}
        <a href="/user">
            <i class="layui-icon layui-icon-username" style="color: #ff7f21;"></i>
            <span class="side_menu">我的</span>
        </a>
    {{end}}
    </p>
</div>